package collections;

import java.util.Arrays;
import java.util.List;

public class demo2 {
	public static void main(String[] args) {

		//拓展：数组 --->集合:调用Arrays类的静态方法asList(T ... t)
		List<String> list = Arrays.asList(new String[]{"AA", "BB", "CC"});
		System.out.println(list);

		List arr1 = Arrays.asList(new int[]{123, 456});
		System.out.println(arr1.toString());
		System.out.println(arr1.size());//1

		List arr2 = Arrays.asList(new Integer[]{123, 456});
		System.out.println(arr2);
		System.out.println(arr2.size());//2


	}
}
